<%@ page contentType="text/html"%>
<%@ include file="/jsp/admin_header.jsp"%>
<%@ include file="/jsp/admin_left_menu.jsp"%>
<%@ page import="it.dei.unipd.healthservice.resource.*"%>
<H1>Creazione Nuova Fabbrica</H1>
<% Fabbrica fabbrica = (Fabbrica)request.getAttribute("fabbrica");%>
<%	if (fabbrica==null)
		fabbrica = new Fabbrica("","","","","","","");
%>
<!--  
      Autore: Giorgio Vitale
-->
<% String completato = (String)request.getAttribute("completato");%>
<%	if (completato!=null){%>
Operazione completata!
<%} else {%>

<form id="registration-form" method="post" action="create_fabbrica" >
	<table class="corpo">
	<tbody>
		<tr>
			<td width="150"><label for="login">login:</label></td>
			<td><input name="login" type="textbox" size="20" value="<%=fabbrica.getLogin()%>"/></td>
		</tr>
		<tr>
			<td width="150"><label for="password">password:</label></td>
			<td><input name="password" type="password" size="20" value="<%=fabbrica.getPassword()%>"/></td>
		</tr>
		<tr>
			<td width="150"><label for="stato">stato:</label></td>
			<td><input name="stato" type="textbox" size="20" value="<%=fabbrica.getStato()%>"/></td>
		</tr>
		<tr>
			<td width="150"><label for="provincia">provincia:</label></td>
			<td><input name="provincia" type="textbox" size="20" value="<%=fabbrica.getProvincia()%>"/></td>
		</tr>
		<tr>
			<td width="150"><label for="citta">citt&agrave;:</label></td>
			<td><input name="citta" type="textbox" size="20" value="<%=fabbrica.getCitta()%>"/></td>
		</tr>
		<tr>
			<td width="150"><label for="cap">cap:</label></td>
			<td><input name="cap" type="textbox" size="5" value="<%=fabbrica.getCap()%>"/></td>
		</tr>
		<tr>
			<td width="150"><label for="indirizzo">indirizzo:</label></td>
			<td><input name="indirizzo" type="textbox" size="20" value="<%=fabbrica.getIndirizzo()%>"/></td>
		</tr>
		<tr>
			<td width="150"> </td>
			<td><input name="submit" type="submit"/></td>
		</tr>
	</tbody>
	</table>
</form>
<% String err = (String)request.getAttribute("errore");%>
<%	if (err!=null){%>
<%= err %>
<%} //err !=null%>
<%} //completato!=null%>

<jsp:include page="/jsp/admin_footer.jsp" flush="true" />
</BODY>
</HTML>